const route = {
  meta: {
    roles: ['workorder_mgt'],
    title: '工单',
    icon: 'gongdan-weixuan',
    activeIcon: 'gongdan-xuanzhong',
    group: 'toolBar'
  },
  path: '/business',
  component: () => import(/* webpackChunkName: "business" */ '@views/index.vue'),
  redirect: '/business/index',
  children: [
    {
      meta: {
        roles: ['workorder_mgt']
      },
      path: 'index',
      name: 'Config',
      component: () => import(/* webpackChunkName: "business" */ '@/afterSales/views/business/index.vue'),
      children: [
        {
          path: 'create',
          name: 'create',
          meta: {
            title: '我创建的',
            group: 'relatedToMe',
            roles: ['workorder_mgt_my_created']
          },
          component: () => import(/* webpackChunkName: "business" */ '@/afterSales/views/business/me/create/index.vue')
        },
        {
          path: 'service/:modelId',
          name: 'service',
          meta: {
            title: '',
            group: 'allBusiness',
            roles: ['workorder_mgt_all']
          },
          component: () => import(/* webpackChunkName: "business" */ '@/afterSales/views/business/all/index.vue')
        },
        {
          path: 'pending',
          name: 'pending',
          meta: {
            title: '待领取',
            group: 'relatedToMe',
            roles: ['workorder_mgt_pending']
          },
          component: () => import(/* webpackChunkName: "business" */ '@/afterSales/views/business/me/pending/index.vue')
        },
        {
          path: 'upcoming',
          name: 'upcoming',
          meta: {
            title: '我的待办',
            group: 'relatedToMe',
            roles: ['workorder_mgt_my_todo']
          },
          component: () => import(/* webpackChunkName: "business" */ '@/afterSales/views/business/me/upcoming/index.vue')
        },
        {
          path: 'party',
          name: 'party',
          meta: {
            title: '我参与的',
            group: 'relatedToMe',
            roles: ['workorder_mgt_my_participated']
          },
          component: () => import(/* webpackChunkName: "business" */ '@/afterSales/views/business/me/participated/index.vue')
        }
      ]
    }
  ]
}
export default route
